package yxy.game.pm2.module.kow;

import yxy.game.pm2.bean.module.rank.RankModule;

public class RankKowGroup extends RankModule {
	private int areaGroupId;
	private int group;

	public int getAreaGroupId() {
		return areaGroupId;
	}

	public void setAreaGroupId(int areaGroupId) {
		this.areaGroupId = areaGroupId;
	}

	public RankKowGroup(int areaGroupId, int group) {
		this.group = group;
		setAreaGroupId(areaGroupId);
		initInfo();
	}

	public int getGroupId() {
		return group;
	}

	@Override
	public String rankName() {
		return "KOWGROUP";
	}

	@Override
	protected long valuePlastic(long value) {
		return value * 100;
	}

	@Override
	protected long valueRestore(long score) {
		return score / 100;
	}

	@Override
	protected String rankKey() {
		return key();
	}

	@Override
	protected String key() {
		return String.format("WORLD:%s:RANK:KOW:GROUP:%s", getAreaGroupId(), group);
	}

}
